inspector: Don't try to access child props of non-containers
authorTimm Bäder <mail@baedert.org>
Tue, 29 Nov 2016 17:32:43 +0000 (18:32 +0100)
committerTimm Bäder <mail@baedert.org>
Sat, 7 Jan 2017 16:19:30 +0000 (17:19 +0100)
gtk/inspector/prop-list.c

index cf75d936c0c13416a0e3928b8def082af45aef47..ff108d788e17d2269f11298cb3b12100a2407c18 100644 (file)
@@ -528,7 +528,7 @@ gtk_inspector_prop_list_set_object (GtkInspectorPropList *pl,
         }
 
       parent = gtk_widget_get_parent (GTK_WIDGET (object));
-      if (!parent)
+      if (!parent || !GTK_IS_CONTAINER (parent))
         {
           gtk_widget_hide (GTK_WIDGET (pl));
           return TRUE;